package com.hrg.rds.biz.waybill.service;


import com.hrg.rds.biz.waybill.domain.instance.WaybillInstance;
import com.hrg.rds.biz.waybill.domain.instance.WaybillInstanceDto;
import com.hrg.rds.biz.waybill.domain.instance.WaybillInstanceVo;
import com.hrg.rds.biz.waybill.domain.template.TemplateParam;
import com.hrg.sys.framework.web.domain.AjaxResult;

import java.util.List;

public interface WaybillInstanceService {
	List<WaybillInstanceVo> selectList(WaybillInstanceDto waybillInstanceDto);

	WaybillInstanceVo selectById(WaybillInstanceDto waybillInstanceDto);

	void updateById(WaybillInstance waybillInstance);
	/**
	 * 暂停运单
	 * @param waybillInstanceId 运单实例id
	 * @return
	/**
	 * 暂停导航
	 * @param waybillInstanceId 运单实例id
	 * @return
	 */
	boolean pause(String waybillInstanceId);
	/**
	 * 恢复导航
	 * @param waybillInstanceId 运单实例id
	 * @return
	 */
	boolean resume(String waybillInstanceId);

	/**
	 * 终止运单
	 * @param waybillInstanceId 运单实例id
	 * @return
	 */
	boolean terminate(String waybillInstanceId);

	/**
	 * 触发运单
	 * @param waybillId 运单id
	 * @param params 运单参数
	 * @param externalId 外部id
	 */
	AjaxResult fireInstance(String waybillId, List<TemplateParam> params, String externalId);
}
